<?php


class Framework_DB_Table_PersonalInfo extends Framework_DB_Table_Common {

	public $tableName = 'PersonalInfo';
	
	public function __construct($db) {
   		
   		// Columns
   		$this->col = array(
	   		// Primary Key 1
	        'idOwner'     => array(
	            'type'    => 'integer',
	            'require' => true
	        ),
	        
	        // Primary Key 2
	        'privacy'     => array(
	            'type'    => 'integer',
	            'require' => true
	        ),
	        
	        
	        'firstName'       => array(
	            'type'    => 'varchar',
	            'size'    => 100,
	            
	            // Quickform settings
	            'qf_label' => 'First Name: ',
	            'qf_type'  => 'text'
	        ),
	        
	            
	       
			'middleName'   => array(
	             'type'    => 'varchar',
	             'size'    => 100,
	             
	             // Quickform settings
	            'qf_label' => 'Middle Name: ',
	            'qf_type'  => 'text'
	        ),
	        
	            
	            
	        'lastName'     => array(
	             'type'    => 'varchar',
	             'size'    => 100,
	             
	             // Quickform settings
	            'qf_label' => 'Last Name: ',
	            'qf_type'  => 'text'
	        ),
	            
	            
	        
	        'gender'       => array(
	             'type'    => 'char',
	             'size'    => 1,
	             
	             // Quickform settings
	             'qf_label' => 'Gender: ',
		         'qf_type'  => 'select',
		         'qf_vals'  => array(
		                'u' => 'Undisclosed',
		         		'm' => 'Male',
		                'f' => 'Female'
		          )
	        ),
	        
	        
	        
	        'location'       => array(
	             'type'    => 'varchar',
	             'size'    => 255,
	             
	             // Quickform settings
	            'qf_label' => 'Location: ',
	            'qf_type'  => 'text'
	        ),
	            
	            
	            
	        
	        'orientation'       => array(
	             'type'    => 'char',
	             'size'    => 1,
	             
	             // Quickform settings
	             'qf_label' => 'Orientation: ',
		         'qf_type'  => 'select',
		         'qf_vals'  => array(
		         		'u' => 'Undisclosed',
		                's' => 'Straight',
		                'g' => 'Gay',
 						'b' => 'Bisexual',
 						'n' => 'Not Sure',
		          )
	        ),
	        
	        'bodyType'       => array(
	             'type'    => 'varchar',
	             'size'    => 2,
	             
	              // Quickform settings
	             'qf_label' => 'Body Type: ',
		         'qf_type'  => 'select',
		         'qf_vals'  => array(
		                'u' => 'Undisclosed',
		                's' => 'Slim',
		                'a' => 'Average',
		                't' => 'Athletic',
		                'e' => 'Few Extra Pounds',
		                'l' => 'Large'
		          )
	        ),
	        
	        
	        
	        'hair'       => array(
	             'type'    => 'varchar',
	             'size'    => 2,
	             
	              // Quickform settings
	             'qf_label' => 'Hair Type: ',
		         'qf_type'  => 'select',
		         'qf_vals'  => array(
		                'u' => 'Undisclosed',
		                'bl'=> 'Blond',
		                'b' => 'Brown',
		                'bk'=> 'Black',
		                'r' => 'Red',
		                'lb'=> 'Light Brown',
		                'db'=> 'Dark Brown',
		                'q' => 'Bald',
		                'o' => 'Other'
		          )
	        ),
	        
	        'eyes'       => array(
	             'type'    => 'varchar',
	             'size'    => 2,
	             
	              // Quickform settings
	             'qf_label' => 'Eye Type: ',
		         'qf_type'  => 'select',
		         'qf_vals'  => array(
		                'u' => 'Undisclosed',
		                'bk'=> 'Black',
		                'bl'=> 'Blue',
		                'b' => 'Brown',
		                'gr'=> 'Grey',
		                'g' => 'Green',
		                'h' => 'Hazel'
		          )
	        ),
	        
	        'ethnicity'       => array(
	             'type'    => 'varchar',
	             'size'    => 2,
	             
	              // Quickform settings
	             'qf_label' => 'Ethnicity: ',
		         'qf_type'  => 'select',
		         'qf_vals'  => array(
		                'u' => 'Undisclosed',
		                'c' => 'Caucasion',
		                'b' => 'Black',
		                'a' => 'Asian',
		                'h' => 'Hispanic',
		                'i' => 'Islander',
		                'n' => 'Native American',
		                'm' => 'Middle Eastern',
		                'i' => 'Indian'
		          )
	        ),
	        
	        'education'    => array(
	             'type'    => 'varchar',
	             'size'    => 2,
	             
	              // Quickform settings
	             'qf_label' => 'Education Level: ',
		         'qf_type'  => 'select',
		         'qf_vals'  => array(
		                'u' => 'Undisclosed',
		                'n' => 'None',
		                'sh'=> 'Some High School',
		                'h' => 'High School',
		                'sc'=> 'Some College',
		                'a' => 'Associates Degree',
		                'b' => 'Bachelors Degree',
		                'm' => 'Masters or Better'
		          )
	        ),
	        
	        'occupation'       => array(
	             'type'    => 'varchar',
	             'size'    => 100,

	             // Quickform settings
	            'qf_label' => 'Occupation: ',
	            'qf_type'  => 'text'
	        ),
	        
	        'employment'       => array(
	             'type'    => 'varchar',
	             'size'    => 2,
	             
	              // Quickform settings
	             'qf_label' => 'Employment: ',
		         'qf_type'  => 'select',
		         'qf_vals'  => array(
		                'u' => 'Undisclosed',
		                's' => 'Student',
		                'p' => 'Part Time',
		                'f' => 'Full Time',
		                'b' => 'Between Jobs',
		                'un'=> 'Unemployed'
		          )
	        ),
	        
	        'faith'       => array(
	             'type'    => 'varchar',
	             'size'    => 2,
	             
	              // Quickform settings
	             'qf_label' => 'Faith: ',
		         'qf_type'  => 'select',
		         'qf_vals'  => array(
		                'u' => 'Undisclosed',
		                'ag'=> 'Agnostic',
		                'b' => 'Buddhist',
		                't' => 'Taoist',
		                'ch'=> 'Christian',
		                'c' => 'Catholic',
		                'p' => 'Protestant',
		                'ba'=> 'Baptist',
		                'mo'=> 'Mormon',
		                'j' => 'Jewish',
		                'mu'=> 'Muslim',
		                'at'=> 'Atheist'
		        )
	        ),
	        
	        'relationshipStatus' => array(
	             'type'    => 'varchar',
	             'size'    => 2,
	             
	              // Quickform settings
	             'qf_label' => 'Relationship Status: ',
		         'qf_type'  => 'select',
		         'qf_vals'  => array(
		                'u' => 'Undisclosed',
		                'sn'=> 'Single and Not Available',
		                'sa'=> 'Single and Available',
		                'ss'=> 'Seeing Someone',
		                'm' => 'Married',
		                'e' => 'Engaged'
		          )
		    ),
	        
	        'birthDate'       => array(
	             'type'    => 'date',
	             // Quickform settings
	             'qf_label' => 'Birth Date: ',
	             'qf_type'  => 'date',
	             'qf_opts'  => array(
		             'minYear'  => 1900, 
		             'maxYear'  => 2000,
		             'format'   => 'm-d-Y'
	             ),
	        ),
	             
	        'aboutMe'       => array(
	            'type'    => 'clob',
	            
	            // form element definition
	            'qf_label' => 'About Me: ',
	            'qf_type'  => 'textarea'
	        )
	             
	    );
	    
	    // Indexes
	    $this->idx = array(
	    	'idOwnerPrivacy' => array(
	    		'cols' => array('idOwner', 'privacy'), 
	    		'type' => 'primary'
			)
	   );
   		
   		parent::__construct($db);
   }
	
	
}

?>